package model

import "gorm.io/gorm"

type Article struct {
	gorm.Model
	Title  string `json:"Title"`
	Desc   string `json:"Desc"`
	Author string `json:"Author"`
}

type User struct {
	gorm.Model
	Username string `json:"Username"`
	Password string `json:"Password"`
}

type UserRole struct {
	gorm.Model
	Uid int `json:"Uid"`
	Rid int `json:"Rid"`
}

type Role struct {
	gorm.Model
	RoleName string `json:"RoleName"`
}

type RoleNode struct {
	gorm.Model
	Rid int `json:"Rid"`
	Nid int `json:"Nid"`
}

type Node struct {
	gorm.Model
	NodeName string `json:"NodeName"`
}

type UserNodeList struct {
	Rid      int
	RoleName string
	Nid      int
	NodeName string
}

type Order struct {
	gorm.Model
	OrderNo    string `gorm:"type:varchar(50)"`
	OrderPrice int    `gorm:"type:int"`
	Pid        int    `gorm:"type:int"`
}
type OrderList struct {
	Id         int
	OrderNo    string
	OrderPrice int
	RepoNo     string
	RepoName   string
}
type Good struct {
	gorm.Model
	GoodName  string `gorm:"type:varchar(50)"`
	GoodPrice int    `gorm:"type:int"`
}
type GoodOrder struct {
	gorm.Model
	GoodId int    `gorm:"type:int"`
	GoodNo string `gorm:"type:varchar(50)"`
}

type GoodOrderList struct {
	OrderNo   string
	GoodName  string
	GoodPrice int
}

type SysGood struct {
	gorm.Model
	GoodNo    string `json:"GoodNo"`
	GoodName  string `json:"GoodName"`
	GoodPrice int    `json:"GoodPrice"`
}
type SysGoodOrder struct {
	gorm.Model
	GoodID  int    `json:"GoodID"`
	OrderNo string `json:"OrderNo"`
}

type SysGoodOrderList struct {
	OrderNo   string
	GoodNo    string
	GoodName  string
	GoodPrice int
}
type Coon struct {
	gorm.Model
	CoonName    string `gorm:"type:varchar(50)"`
	CoonStatus  string `gorm:"type:varchar(50)"`
	CoonAddress string `gorm:"type:varchar(50)"`
}

type CoonGood struct {
	gorm.Model
	Coongoodno   string `gorm:"type:varchar(50)"`
	CoongoodTime string `gorm:"type:varchar(50)"`
}
type CoonGoodList struct {
	CoonName     string
	CoonStatus   string
	CoonAddress  string
	Coongoodno   string
	CoongoodTime string
}
type Car struct {
	gorm.Model
	CarCode string `json:"CarCode"`
	CarName string `json:"CarName"`
	CarNum  string `json:"CarNum"`
}

type CarOrder struct {
	gorm.Model
	OrderNo     string `json:"OrderNo"`
	FromAddress string `json:"FromAddress"`
	ToAddress   string `json:"ToAddress"`
	CarID       int    `json:"CarID"`
}

type CarOrderList struct {
	FromAddress string
	OrderNo     string
	ToAddress   string
	CarCode     string
	CarName     string
	CarNum      string
}
